package cc.comac.mom.dao.base;

import java.util.List;

import cc.comac.mom.entity.base.BaseEntity;

public interface BaseEntityDao<T extends BaseEntity> {
	
	public int save(T entity);
	public int delete(T entity);
	public int update(T entity);
	
	public int saveBatch(List<T> entity);
	public int deleteBatch(List<T> entity);
	public int updateBatch(List<T> entity);
	
	public T getById(long id);
	
	
	//以下方法，建议放到群组对象或者具体对象里面
	//public T getByName(String name);
	//public T getByCode(String code);
	//public void batchDeleteByIds(List<T> list);

}
